---
title: "JOP Replication File"
output: pdf_document
date: "2024-01-26"
---

This file can be used to reproduce the descriptive statistics related to stalemates that appear in the "Discussion" section of the main text.

```{r setup, include=FALSE}
library(dplyr)
mids <- read.csv("MIDA_4.2.csv") #reads the data in
```

```{r}
#The first step is to subset to MIDs that don't end up as wars
mids.peace <- mids %>% filter(hostlev < 5) 

#This produces 2,185 peaceful mids

#Next step is to subset to those that end in stalemates
mids.stalemates <- mids %>% filter(hostlev < 5 & outcome ==5)

#This produces 1,508 stalemates

#Next step is to subset to those that end in stalemates without negotiated outcomes
mids.unsettled.stalemates <- mids  %>% filter(hostlev < 5 & outcome ==5 & settle ==3)
#This produces 1,442 stalemates without negotiated outcomes
```
